import { Body, Inject, Post } from '@midwayjs/core';
import {
  CoolController,
  BaseController,
  CoolTag,
  TagTypes,
  CoolUrlTag,
  CoolUrlTagData,
} from '@cool-midway/core';
import { UserInfoEntity } from '../../../user/entity/info';
import { AdvertisementEntity } from '../../entity';
import { AdvertisementService } from '../../service';

/**
 * 轮播图
 */
@CoolController({
  api: ['add', 'delete', 'update', 'info', 'list', 'page'],
  entity: AdvertisementEntity,
  service: AdvertisementService,
})
// add 接口忽略token
@CoolUrlTag({
  key: TagTypes.IGNORE_TOKEN,
  value: ['list', 'page'],
})
export class AdvertisementController extends BaseController {
  @Inject()
  tag: CoolUrlTagData;
}
